<!--  -->
<template>
  <div class="tables-system-type-2">
    <el-row v-loading="systemItemLoading">
      <el-table :data="systemItemList" :height="340" :border="true" style="width: 100%">
        <el-table-column label="序号" width="60" align="center">
          <template slot-scope="scope">
            <span>{{scope.$index + 1}}</span>
          </template>
        </el-table-column>
        <el-table-column :show-overflow-tooltip="true" prop="sarticle.title" label="标题">
        </el-table-column>
        <!-- <el-table-column type="selection" width="55">
        </el-table-column> -->
      </el-table>
    </el-row>
  </div>
</template>

<script>
import ImagesEmpty from '@/assets/images/image-empty.png'
import * as functions from '@/core/functions.js'
export default {
  props: {
    systemItemList: {
      type: Array
    },
    systemItemLoading: {
      type: Boolean
    }
  },
  data () {
    return {
    }
  },
  methods: {
    categoryFormatter (row, column, cellValue, index) {
      if (!row.categoryQuote) {
        row.categoryQuote = {}
      }
      if (!row.categoryQuote.scategories) {
        row.categoryQuote.scategories = {}
      }
      if (!row.categoryQuote.scategories.name) {
        row.categoryQuote.scategories.name = '未定义'
      }
    },
    imageUrl (row) {
      if (!row || !row.repertoryQuote || !row.repertoryQuote.hrepertory) {
        return ImagesEmpty
      }
      let src = functions.getRepertoryImageSrcByHostRepertory(row.repertoryQuote.hrepertory)
      return src
    }
  }
}

</script>

<style scoped>
.tables-system-type-2 {
  margin-top: 10px;
}
</style>
